#ifndef BUNNY_H
#define BUNNY_H

#include "Entity/BaseEntity.h"
#include "FSM/StateMachine.h"
#include "bunny_states.h"
#include "Messaging/Telegram.h"
#include <iostream>
using namespace std;


class Bunny: public BaseEntity {
public:
	Bunny(int p_id):
		m_energy(20),
		BaseEntity(p_id)
	{
		m_stateMachine = new StateMachine<Bunny>(this);
		m_stateMachine->setCurrentState(new State_BunnyRun());
	}


	virtual void update() {
		m_stateMachine->update();
	}

	virtual bool handleMessage(const Telegram& p_t) {
		m_stateMachine->handleMessage(p_t);
		return true;
	}


	int m_energy;
	StateMachine<Bunny>* m_stateMachine;
};

#endif